package com.ymttest.database.sqlwapper;

import java.util.List;

import com.ymt.database.SqlManager;
import com.ymttest.database.model.YmtProductFreezeStockLog;
import com.ymttest.database.model.YmtStockChangeDetail;

public class YmtProductFreezeStockLogWapper {
	SqlManager manage;

	public YmtProductFreezeStockLogWapper() {
		manage = new SqlManager("intpro");
	}
	
	public List<YmtProductFreezeStockLog> selectByProductId(String productId)throws InterruptedException{
		  @SuppressWarnings("unchecked")
		List<YmtProductFreezeStockLog>  ymtProductFreezeStockLog = manage.getSelectResults(
		            "com.ymttest.database.mapping.YmtProductFreezeStockLogMapper.selectByProductId", productId);
		    manage.commit();
		    return ymtProductFreezeStockLog;
	}
	
	
	public List<YmtProductFreezeStockLog> selectByFreezeId(String freezeId)throws InterruptedException{
		  @SuppressWarnings("unchecked")
		List<YmtProductFreezeStockLog>  ymtProductFreezeStockLog = manage.getSelectResults(
		            "com.ymttest.database.mapping.YmtProductFreezeStockLogMapper.selectByFreezeId", freezeId);
		    manage.commit();
		    return ymtProductFreezeStockLog;
	}
	
	
	public static void main(String[] args) throws InterruptedException {
		System.out.println(new YmtProductFreezeStockLogWapper().selectByFreezeId("DJ202133162").get(0).getCatalogId());
	}
}
